00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef _matrix_implementation_h_
00027 #define _matrix_implementation_h_
00028
00029 #include <gridpack/parallel/distributed.hpp>
00030 #include <gridpack/utilities/uncopyable.hpp>
00031 #include <gridpack/utilities/complex.hpp>
00032 #include <gridpack/math/matrix_interface.hpp>
00033
00034 namespace gridpack {
00035 namespace math {
00036
00037
00038
00039
00040 template <typename T, typename I = int>
00041 class MatrixImplementation
00042 : private utility::Uncopyable,
00043 public parallel::Distributed,
00044 public BaseMatrixInterface<T, I>
00045 {
00046 public:
00047
00048
00049 MatrixImplementation(const parallel::Communicator& comm)
00050 : utility::Uncopyable(), parallel::Distributed(comm)
00051 {
00052 }
00053
00054
00055 virtual ~MatrixImplementation(void)
00056 {
00057 }
00058
00059
00060 MatrixImplementation *clone(void) const
00061 {
00062 return this->p_clone();
00063 }
00064
00065
00066 MatrixImplementation *localClone(void) const
00067 {
00068 return this->p_localClone();
00069 }
00070
00071
00072
00073 protected:
00074
00075
00076 virtual MatrixImplementation *p_clone(void) const = 0;
00077
00078
00079 virtual MatrixImplementation *p_localClone(void) const = 0;
00080 };
00081
00082 }
00083 }
00084
00085
00086
00087 #endif